package com.css.fxfzfxqh.constants;

import lombok.AllArgsConstructor;
import lombok.Getter;

@Getter
@AllArgsConstructor
public enum IntensityEnum {

    INTENSITY6(6,"Ⅵ"),
    INTENSITY7(7,"Ⅶ"),
    INTENSITY8(8,"Ⅷ"),
    INTENSITY9(9,"Ⅸ"),
    INTENSITY10(10,"Ⅹ");

    private final Integer code;
    private final String intensity;

    public static String getByCode(Integer code) {
        for (IntensityEnum value : IntensityEnum.values()) {
            if (value.getCode().equals(code)) {
                return value.intensity;
            }
        }
        return null;
    }
}
